home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat4 / dmedia / datframe.z / datframe
Encoding:
Text File  |  2002-10-03  |  31.3 KB  |  727 lines

  1.  
  2.  
  3.  
  4. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      datframe - structure of a frame of audio data on Digital Audio Tape (DAT)
  10.  
  11. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  12.      ####iiiinnnncccclllluuuuddddeeee <<<<ddddaaaattttaaaauuuuddddiiiioooo....hhhh>>>>
  13.  
  14. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  15.      The Digital Audio Tape (DAT) recorder system is very complex.  This man
  16.      page gives the most useful and relevant information for DAT use in
  17.      professional systems.  It is by no means comprehensive.  Conflicts and
  18.      questions must be resolved by reference to the definitive _D_A_T _C_o_n_f_e_r_e_n_c_e
  19.      specification referenced below.
  20.  
  21.      Audio on Digital Audio Tapes (DAT) is blocked into _f_r_a_m_e_s.  A DAT
  22.      recording has 33.33 frames every second.  One frame of data contains both
  23.      audio and non-audio data (known as subcodes).  A program reading or
  24.      writing a DAT in audio mode must _r_e_a_d(_2) or _w_r_i_t_e(_2) a minimum of one DAT
  25.      frame.
  26.  
  27.      The _d_t_f_r_a_m_e structure, describing the content of a frame of DAT data, is
  28.      defined in <<<<ddddaaaattttaaaauuuuddddiiiioooo....hhhh>>>> as follows:
  29.  
  30.            typedef struct dtframe {
  31.               char audio[DTDA_DATASIZE];
  32.               struct dtsubcode sc;
  33.            } DTFRAME
  34.  
  35.  
  36.      Audio samples in the _a_u_d_i_o array are linearly encoded in a 16-bit 2's
  37.      complement format.  Encoding is carried out either without pre-emphasis
  38.      or with a first order 50/15 Ms pre-emphasis.  Pre-emphasis is not
  39.      recommended for professional use.  Other encodings are supported by the
  40.      DAT format but are not permitted in professional use.  The data stream
  41.      contains two interleaved channels, usually used as the left and right
  42.      channels of a stereo signal.  The sample representing the left channel is
  43.      first, followed by the sample representing the right channel.  The _D_A_T
  44.      _C_o_n_f_e_r_e_n_c_e recommends sampling both both left and right channels
  45.      simultaneously during recording.  The IRIS Indigo and Personal IRIS 4D/35
  46.      audio ADC hardware samples both channels simultaneously.
  47.  
  48.      The least significant byte of each 16-bit value is first.  The bytes need
  49.      to be swapped in order to match the native byte ordering of the IRIS
  50.      Indigo and Personal IRIS 4D/35 and their audio hardware.  So each 4-byte
  51.      chunk of the data array represents a pair of samples (1 left plus 1
  52.      right) as follows.  Byte 0 is the least significant byte of the left
  53.      channel sample; byte 1 is the most significant byte of the left channel
  54.      sample.  Byte 2 is the least significant byte of the simultaneous right
  55.      channel sample; byte 3 is the most significant byte of the simultaneous
  56.      right channel sample.
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  71.  
  72.  
  73.  
  74.      DTDA_DATASIZE is 5760 bytes.
  75.  
  76.    SSSSuuuubbbbccccooooddddeeeessss
  77.      The _d_t_s_u_b_c_o_d_e structure contains subcode information that is recorded on
  78.      several different areas of the tape.  ssssttttrrrruuuucccctttt ddddttttssssuuuubbbbccccooooddddeeee is defined in
  79.      _d_a_t_a_u_d_i_o._h as follows:
  80.  
  81.            typedef struct dtsubcode {
  82.               struct dtsubcodepack packs[7];
  83.               struct dtsubid {
  84.                   unchar ctrlid:4, dataid:4;
  85.                   unchar pno1:4, numpacks:4;
  86.                   unchar pno2:4, pno3:4;
  87.                   unchar ipf;
  88.               } sid;
  89.               struct dtmainid {
  90.                   unchar fmtid:2;
  91.                   unchar emphasis:2;
  92.                   unchar sampfreq:2;
  93.                   unchar numchans:2;
  94.                   unchar quantization:2;
  95.                   unchar trackpitch:2;
  96.                   unchar copy:2;
  97.                   unchar pack:2;
  98.               } mid;
  99.            } DTSUBCODE;
  100.  
  101.  
  102.      In referring to the _D_A_T _C_o_n_f_e_r_e_n_c_e specification, you need to know that
  103.      the _m_i_d field contains the bits from the ID field of the main data area
  104.      otherwise known as the MMMMaaaaiiiinnnn IIIIDDDD bits.  The _s_i_d field contains the bits
  105.      from the ID field of the sub data area, otherwise known as SSSSuuuubbbb IIIIDDDD bits.
  106.      The _p_a_c_k_s field contains all seven data packs from the sub-data area of
  107.      the tape.
  108.  
  109.    MMMMaaaaiiiinnnn IIIIDDDD BBBBiiiittttssss
  110.      The bits of the mmmmiiiidddd field have the following meanings and values:
  111.  
  112.                      value   meaning
  113.      ffffmmmmttttiiiidddd::::            0     for audio use
  114.                        1     reserved
  115.                        2     reserved
  116.                        3     reserved
  117.  
  118.                      value   meaning
  119.      eeeemmmmpppphhhhaaaassssiiiissss::::         0     off
  120.                        1     50/15 Msec
  121.                        2     reserved
  122.                        3     reserved
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  137.  
  138.  
  139.  
  140.                      value   meaning
  141.      ssssaaaammmmppppffffrrrreeeeqqqq::::         0     48kHz
  142.                        1     44.1kHz
  143.                        2     32kHz
  144.                        3     reserved
  145.  
  146.                      value   meaning
  147.      nnnnuuuummmmcccchhhhaaaannnnssss::::         0     2 channels
  148.                        1     4 channels
  149.                        2     reserved
  150.                        3     reserved
  151.  
  152.                      value   meaning
  153.      qqqquuuuaaaannnnttttiiiizzzzaaaattttiiiioooonnnn::::     0     16-bit linear
  154.                        1     12-bit non-linear
  155.                        2     reserved
  156.                        3     reserved
  157.  
  158.                      value   meaning
  159.      ttttrrrraaaacccckkkkppppiiiittttcccchhhh::::       0     normal track mode
  160.                        1     wide track mode
  161.                        2     reserved
  162.                        3     reserved
  163.  
  164.                      value   meaning
  165.      ccccooooppppyyyy::::             0     copy permitted
  166.                        1     reserved
  167.                        2     copy prohibited
  168.                        3     reserved
  169.  
  170.      These bits are always present and must be recorded when making your own
  171.      recordings.
  172.  
  173.      The ppppaaaacccckkkk field is optional.  It should be filled with zero when not being
  174.      used.  The bits of the ppppaaaacccckkkk field are assembled with the bits of the pack
  175.      fields from 31 other frames to build one 8-byte subcode pack.  These
  176.      packs are duplicated in the sub data area from where they are much easier
  177.      to recover.  All seven packs can be found in the ppppaaaacccckkkkssss array in DDDDTTTTFFFFRRRRAAAAMMMMEEEE....
  178.  
  179.    SSSSuuuubbbb IIIIDDDD BBBBiiiittttssss
  180.      The ccccttttrrrrlllliiiidddd field is a bit field with the following meanings:
  181.  
  182.           bbbbiiiitttt nnnnaaaammmmeeee          mmmmeeeeaaaannnniiiinnnngggg
  183.           0   TOC ID        set if this program is stored
  184.                             in the table of contents
  185.           1   Shortening ID set for 33 +_ 3 frames at the
  186.                             start of shortening play
  187.           2   Start ID      set for 300 +_ 30 frames at
  188.                             the start of a track
  189.           3   Priority ID   set when the program number is
  190.                             recorded and is well defined
  191.  
  192.  
  193.  
  194.  
  195.                                                                         PPPPaaaaggggeeee 3333
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  203.  
  204.  
  205.  
  206.      The ddddaaaattttaaaaiiiidddd field is zero for audio use.  All other values are reserved.
  207.  
  208.      ppppnnnnoooo1111,,,, ppppnnnnoooo2222 and ppppnnnnoooo3333 are 3 BCD digits indicating the current program
  209.      number.  ppppnnnnoooo1111 is the most significant digit.  Program numbering starts
  210.      with the value 001 and has to increase by increments of one.  The maximum
  211.      program number is 799 so ppppnnnnoooo can have values from 0 - 7, and ppppnnnnoooo2222 and
  212.      ppppnnnnoooo3333 can have values from 0 - 9.  The program number can also be one of
  213.      three special values 0AA means the program number is not currently valid.
  214.      0BB means we are in the lead-in area.  0EE means we are in the lead-out
  215.      area.
  216.  
  217.      The program number is only required to be valid when ssssttttaaaarrrrttttiiiidddd is 1, i.e.
  218.      for 300 +_ 30 frames.  so it is likely to disappear and be replaced by 0AA
  219.      shortly after a track starts.
  220.  
  221.      nnnnuuuummmmppppaaaacccckkkkssss is the number of subcode packs actually used in this frame.  It
  222.      usually indicates that all seven packs are recorded even when they are
  223.      all zero.
  224.  
  225.      iiiippppffff contains the interpolation flags, one for each channel as follows:
  226.  
  227.           BBBBiiiitttt    CCCChhhhaaaannnnnnnneeeellll
  228.           0x40   Left IPF
  229.           0x20   Right IPF
  230.  
  231.      The interpolation flags indicate when uncorrectable errors have been
  232.      detected during playback leading the DAT drive to interpolate the missing
  233.      data.  It is usually advisable not to play the audio data from a frame
  234.      with these flags set.
  235.  
  236.      Most of SSSSuuuubbbb IIIIDDDD is optional.  Only ddddaaaattttaaaaiiiidddd is required and must be zero.
  237.      If the bits of ccccttttrrrrlllliiiidddd are zero, the bits of the rest of SSSSuuuubbbb IIIIDDDD may also
  238.      be set to zero and will be ignored.
  239.  
  240.    SSSSuuuubbbbccccooooddddeeee PPPPaaaacccckkkkssss
  241.      Nine different pack items are currently defined and seven are reserved.
  242.      The nine items are:
  243.  
  244.           PPPPaaaacccckkkk IIIIDDDD    CCCCoooonnnntttteeeennnntttt
  245.           0000       no information
  246.           0001       Program Time
  247.           0010       Absolute Time
  248.           0011       Running Time/Pro R-Time
  249.           0100       Table of Contents
  250.           0101       Date
  251.           0110       Catalog Number
  252.           0111       International Standard Recording Code
  253.           1000       Pro Binary
  254.  
  255.    PPPPrrrrooooggggrrrraaaammmm TTTTiiiimmmmeeee
  256.      Program Time indicates the time from the beginning of the program.  It is
  257.      stored in a _d_t_t_i_m_e_p_a_c_k structure defined in _d_a_t_a_u_d_i_o._h as follows:
  258.  
  259.  
  260.  
  261.                                                                         PPPPaaaaggggeeee 4444
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  269.  
  270.  
  271.  
  272.            /*
  273.             * The timecode structure looks like this:
  274.             *
  275.             *      struct dttimecode {
  276.             *          unchar hhi:4, hlo:4;
  277.             *          unchar mhi:4, mlo:4;
  278.             *          unchar shi:4, slo:4;
  279.             *          unchar fhi:4, flo:4;
  280.             *      };
  281.             *
  282.             * This structure is identical to mtaudtimecode in sys/mtio.h so
  283.             */
  284.            #define dttimecode mtaudtimecode
  285.  
  286.            /* pack for ptime, atime, rtime and pro-rtime */
  287.            struct dttimepack {
  288.               unchar id:4, flag:1, pno1:3, pno2:4, pno3:4;
  289.               struct dtpackedbcd {unchar dhi:4, dlo:4;} index;
  290.               struct dttimecode tc;
  291.               unchar parity;
  292.            };
  293.  
  294.  
  295.      The program number is stored in ppppnnnnoooo1111,,,, ppppnnnnoooo2222,,,, and ppppnnnnoooo3333 as 3 BCD digits
  296.      exactly like the SSSSuuuubbbb IIIIDDDD field. That information is duplicated here.
  297.      iiiinnnnddddeeeexxxx is the index number of the current subdivision within the program.
  298.      The index number is expressed as 2 BCD digits.  AA indicates that the
  299.      index number is invalid.  A program may be preceded by an index number of
  300.      00 with the same program number.  This represents the _m_u_s_i_c _i_n_t_e_r_v_a_l or
  301.      pause between tracks.  Valid index numbers are 01 to 99.  Within a
  302.      program, the first value of the index number is 01 and the value of the
  303.      index number has to increase by one.
  304.  
  305.      The program time is represented by 2 BCD digits each for hours, minutes,
  306.      seconds and frames.  Hours range from 00 to 99, and minutes and seconds
  307.      from 00 to 59.  Over a three second period, frames ranges from 00 to 32,
  308.      00 to 32, and 00 to 33.  In other words if (seconds modulo 3) is 0 or 1,
  309.      frames ranges from 00 to 32.  If (seconds modulo 3) is 2, frames ranges
  310.      from 00 to 33.  AA indicates the the program time is invalid.  The
  311.      program time is set to zero at the start position of a program and
  312.      increases within the program.  The start position of a program is the
  313.      first position where the program number is renewed (changed) and the
  314.      index number is not 00.
  315.  
  316.    AAAAbbbbssssoooolllluuuutttteeee TTTTiiiimmmmeeee
  317.      Absolute time is stored in a ssssttttrrrruuuucccctttt ddddttttttttiiiimmmmeeeeppppaaaacccckkkk identical to program
  318.      time's.  Absolute time is set to 00 at the start of the first program on
  319.      the tape and increases throughout the tape except on the lead-in area
  320.      (program number 0BB).  The time decreases on the lead-in area and is set
  321.      to zero at the end point of the lead-in area.
  322.  
  323.  
  324.  
  325.  
  326.  
  327.                                                                         PPPPaaaaggggeeee 5555
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  335.  
  336.  
  337.  
  338.      When the first program cannot begin after the time is set to zero, the
  339.      time should be zero continuously until the first program begins.  The
  340.      program number of this area should be 0BB and this area should be less
  341.      than 33 frames.
  342.  
  343.    RRRRuuuunnnnnnnniiiinnnngggg TTTTiiiimmmmeeee
  344.      Running time is stored in a pack with ID 3, and the ffffllllaaaagggg bit zero.  The
  345.      pack is a time pack identical to program and absolute times'.  The
  346.      running time is a continuously increasing time code beginning from some
  347.      value at the start point of each recording.  The time increases within
  348.      one recording.
  349.  
  350.    PPPPrrrroooo RRRR TTTTiiiimmmmeeee
  351.      Pro R time is a variation on the running time pack for professional use.
  352.      Pro R time is indicated when the ffffllllaaaagggg bit is one.  Pro R time is stored
  353.      in a ddddttttpppprrrroooottttiiiimmmmeeeeppppaaaacccckkkk defined in _d_a_t_a_u_d_i_o._h as follows:
  354.  
  355.            /* pack for pro-rtime */
  356.            struct dtprotimepack {
  357.               unchar id:4, flag:1, fill:1, sid:2;
  358.               unchar freq:2, xrate:3, msb:3;
  359.               unchar lsb;
  360.               struct dttimecode tc;
  361.               unchar parity;
  362.            };
  363.  
  364.  
  365.      Pro R time stores a running time in the ttttcccc field just like running time.
  366.      The other fields give addition information about the stored time value.
  367.  
  368.      The ssssiiiidddd field indicates the type of time code recorded as follows:
  369.  
  370.           vvvvaaaalllluuuueeee   mmmmeeeeaaaannnniiiinnnngggg
  371.           00      IEC (SMPTE) timecode (IEC 461)
  372.           01      local sample address code of Pro DIO time code.
  373.           10      time-of-day code of Pro DIO time code (IEC 958)
  374.           11      reserved
  375.  
  376.      The ffffrrrreeeeqqqq field indicates the sampling frequency used for the time
  377.      conversion to Pro R time as follows:
  378.  
  379.           vvvvaaaalllluuuueeee   mmmmeeeeaaaannnniiiinnnngggg
  380.           00      48kHz
  381.           01      44.1kHz
  382.           10      32kHz
  383.           11      reserved
  384.  
  385.      When the ssssiiiidddd field indicates IEC (SMPTE) time code, the xxxxrrrraaaatttteeee field
  386.      indicates the transmission rate of the time code as follows:
  387.  
  388.  
  389.  
  390.  
  391.  
  392.  
  393.                                                                         PPPPaaaaggggeeee 6666
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  401.  
  402.  
  403.  
  404.           vvvvaaaalllluuuueeee   mmmmeeeeaaaannnniiiinnnngggg
  405.           000     30Hz
  406.           001     29.97Hz, non-drop frame
  407.           010     29.97Hz, drop frame
  408.           011     25Hz
  409.           100     24Hz
  410.           101     reserved
  411.           110     reserved
  412.           111     reserved
  413.  
  414.      For any other value of ssssiiiidddd,,,, this field must have the value 000.
  415.  
  416.      The mmmmssssbbbb,,,, and llllssssbbbb fields provide 11 bits of binary data.  When ssssiiiidddd
  417.      indicates IEC (SMPTE) time code these bits record a _T_i_m_e _c_o_d_e _M_a_r_k_e_r (_T_C
  418.      _M_a_r_k_e_r). TC Marker is the time difference between the IEC time code frame
  419.      and the DAT frame.
  420.  
  421.      When ssssiiiidddd indicates one of the Pro DIO time codes, the binary data records
  422.      the 32-bit binary code corresponding to the first sample of a DAT frame
  423.      converted into hour, minute, seconds, frame and sample (called the sample
  424.      number).
  425.  
  426.      The range of value indicated by these 11 bits is different for each value
  427.      of ffffrrrreeeeqqqq as shown in the following table:
  428.  
  429.           ffffrrrreeeeqqqquuuueeeennnnccccyyyy   rrrraaaannnnggggeeee
  430.           48kHz       0 - 1439
  431.           44.1kHz     0 - 1322
  432.           32kHz       0 - 959.
  433.  
  434.    TTTTaaaabbbblllleeee ooooffff CCCCoooonnnntttteeeennnnttttssss
  435.      The TOC pack contains one entry from the table of contents.  The TOC is
  436.      stored in a _s_t_r_u_c_t _d_t_t_o_c_p_a_c_k defined in _d_a_t_a_u_d_i_o._h as follows:
  437.  
  438.            /* pack for table of contents */
  439.            struct dttocpack {
  440.               unchar id:4, flag:1, pno1:3, pno2:4, pno3:4;
  441.               struct dtpackedbcd point;
  442.               struct dttimecode atime;
  443.               unchar parity;
  444.            };
  445.  
  446.  
  447.      The table of contents may be recorded repeatedly over the entire length
  448.      of the tape or only at the beginning of the tape.  In the first case it
  449.      is called _r_e_p_e_a_t_e_d _T_O_C (_R-_T_O_C). In the latter case it is called _u_s_e_r'_s
  450.      _T_O_C (_U-_T_O_C).
  451.  
  452.      The standard table of contents entry has a program number in ppppnnnnoooo1111,,,, ppppnnnnoooo2222
  453.      and ppppnnnnoooo3333,,,, and an index number in ppppooooiiiinnnntttt.... The starting position of that
  454.      program, index pair is given in aaaattttiiiimmmmeeee.... Several special values of ppppnnnnoooo and
  455.      iiiinnnnddddeeeexxxx with specific meanings are also used.  The following table shows
  456.  
  457.  
  458.  
  459.                                                                         PPPPaaaaggggeeee 7777
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  467.  
  468.  
  469.  
  470.      these values.
  471.  
  472.           PPPPooooiiiinnnntttt   PPPPrrrrooooggggrrrraaaammmm NNNNuuuummmmbbbbeeeerrrr        AAAAttttiiiimmmmeeee
  473.           AA      0BB                   all "0"
  474.           BB      PNO of TOC area       all "0"
  475.           B0      No. of TOC entries    all "0"
  476.           A0      No. of 1st program    start of 1st program
  477.           A1      No. of last program   start of last program
  478.           C0      No. of a skip area    start of skip area
  479.           C1      No. of a skip area    end of skip area
  480.           CC      0BB                   all "0"
  481.           EE      PNO of TOC area       all "0"
  482.  
  483.      Point BB is the beginning of the table of contents.  Point CC is a
  484.      continuation of the table of contents.  Point EE is the end of the table
  485.      of contents.
  486.  
  487.      A location in absolute time is found by scanning the tape at 150X play
  488.      speed.  Since it is possible to do exactly the same kind of search for a
  489.      program number, the table of contents is not terribly useful.
  490.  
  491.    DDDDaaaatttteeee
  492.      The date pack is a time stamp giving the time and date of recording.  It
  493.      is stored in a ssssttttrrrruuuucccctttt ddddttttddddaaaatttteeeeppppaaaacccckkkk which is defined in _d_a_t_a_u_d_i_o._h as
  494.      follows:
  495.  
  496.            /* pack for date */
  497.            struct dtdatepack {
  498.               unchar id:4, dayow:4;
  499.               struct dtpackedbcd year;
  500.               struct dtpackedbcd month;
  501.               struct dtpackedbcd day;
  502.               struct dtpackedbcd hour;
  503.               struct dtpackedbcd min;
  504.               struct dtpackedbcd sec;
  505.               unchar parity;
  506.            };
  507.  
  508.  
  509.    CCCCaaaattttaaaalllloooogggg NNNNuuuummmmbbbbeeeerrrr
  510.      The catalog number pack gives the catalog number expressed in 13 BCD
  511.      digits according to the UPS/EAN-Code.  It is stored in a ssssttttrrrruuuucccctttt
  512.      ddddttttccccaaaattttaaaallllooooggggppppaaaacccckkkk defined in _d_a_t_a_u_d_i_o._h as follows:
  513.  
  514.            /* pack for catalog number */
  515.            struct dtcatalogpack {
  516.               unchar id:4, n1:4;
  517.               struct dtpackedbcd nrest[6];
  518.               unchar parity;
  519.            };
  520.  
  521.  
  522.  
  523.  
  524.  
  525.                                                                         PPPPaaaaggggeeee 8888
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  533.  
  534.  
  535.  
  536.      The catalog number does not change on a tape.  When this item is present
  537.      it occupies at least one of 100 successive frames.
  538.  
  539.    IIIInnnntttteeeerrrrnnnnaaaattttiiiioooonnnnaaaallll SSSSttttaaaannnnddddaaaarrrrdddd RRRReeeeccccoooorrrrddddiiiinnnngggg CCCCooooddddeeee
  540.      The ISRC gives a unique identification code to a recording.  It is stored
  541.      in a _s_t_r_u_c_t _d_t_i_d_e_n_t_p_a_c_k which is defined in _d_a_t_a_u_d_i_o._h as follows:
  542.  
  543.            /* pack for ISRC */
  544.            struct dtidentpack {
  545.               unchar id:4, point:2, fill:2;
  546.               union {
  547.                   struct {
  548.                       unchar country[2];
  549.                       unchar owner[3];
  550.                       unchar fill;
  551.                   } point0;
  552.                   struct {
  553.                       struct dtpackedbcd year;
  554.                       struct dtpackedbcd serial[3]; /* serial is 1st 5 digits */
  555.                       unchar fill[2];
  556.                   } point1;
  557.               } data;
  558.               unchar parity;
  559.            };
  560.  
  561.  
  562.      When ppppooooiiiinnnntttt is zero the pack contains the country and owner codes.  When
  563.      ppppooooiiiinnnntttt is one the pack contains the year and serial number.  Country and
  564.      owner are encoded in a six-bit code representing digits and upper case
  565.      letters.  [See _c_d_f_r_a_m_e(_4) for the code.]  Year and serial number are BCD
  566.      digits.
  567.  
  568.      The ISRC can only change immediately after the program number changes.
  569.  
  570.      When this item is present it occupies at least one of 100 successive
  571.      frames.
  572.  
  573.    PPPPrrrroooo BBBBiiiinnnnaaaarrrryyyy
  574.      The Pro Binary pack contains either the binary group data of IEC (SMPTE)
  575.      time code or the status data of Pro DIO time code.  It is stored in a
  576.      ssssttttrrrruuuucccctttt ddddttttpppprrrroooobbbbiiiinnnnaaaarrrryyyyppppaaaacccckkkk which is defined in _d_a_t_a_u_d_i_o._h as follows:
  577.  
  578.            /* pack for pro-binary */
  579.            struct dtprobinarypack {
  580.               unchar id:4, fill:2, sid:2;
  581.               union {
  582.                   struct bgd {
  583.                       unchar fill;
  584.                       unchar tcbits;
  585.                       struct dtpackedbcd bg[4];
  586.                   } bgd;  /* binary group data of IEC time code */
  587.                   struct csid {
  588.  
  589.  
  590.  
  591.                                                                         PPPPaaaaggggeeee 9999
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  599.  
  600.  
  601.  
  602.                       unchar csbytes[6];
  603.                   } csid; /* channel status id of Pro DIO time code */
  604.                   struct cod {
  605.                       unchar fill[2];
  606.                       unchar cod[4];
  607.                   } cod; /* alphanumeric origin data of Pro DIO */
  608.                   struct cdd {
  609.                       unchar fill[1];
  610.                       unchar flags;
  611.                       unchar cdd[4];
  612.                   } cdd;  /* alphanumeric destination data of Pro DIO */
  613.               } data;
  614.               unchar parity;
  615.            };
  616.  
  617.  
  618.      ssssiiiidddd is a subpack identification identifying what is in this pack as
  619.      follows:
  620.  
  621.           vvvvaaaalllluuuueeee   ccccoooonnnntttteeeennnntttt
  622.           00      binary group data of IEC (SMPTE) time code
  623.           01      channel status ID of Pro DIO time code
  624.           10      alphanumeric origin data of Pro DIO
  625.           11      alphanumeric destination data of Pro DIO
  626.  
  627.      The IEC (SMPTE) binary group data consists of binary group and time code
  628.      bits.  The binary groups are stored as BCD digits in bbbbgggg.... The eighth
  629.      binary group is stored in bbbbgggg[[[[0000]]]]....ddddhhhhiiii.... The seventh binary group is stored
  630.      in bbbbgggg[[[[0000]]]]....ddddlllloooo.... The groups continue in descending order through the array
  631.      with the second group in bbbbgggg[[[[3333]]]]....ddddhhhhiiii and the first group in bbbbgggg[[[[3333]]]]....ddddlllloooo....
  632.  
  633.      The time code bits are used as follows:
  634.  
  635.           bbbbiiiitttt   IIIIEEEECCCC bbbbiiiitttt   555522225555////66660000              666622225555////55550000
  636.           0     10        drop frame          unassigned
  637.           1     11        color frame         color lock
  638.           2     27        phase correction    binary group flag
  639.           3     43        binary group flag   binary group flag
  640.           4     58        unassigned          unassigned
  641.           5     59        binary group flag   phase correction
  642.           6               not used
  643.           7               not used
  644.  
  645.      When the IEC (SMPTE) time code is recorded for a given frame, the binary
  646.      group data must also be recorded.
  647.  
  648.      The channel status ID consists of bytes 0 to 5 of the channel status data
  649.      of the IEC serial digital interface stored in bytes 0 to 5 of
  650.      ddddaaaattttaaaa....ccccddddiiiidddd....ccccssssbbbbyyyytttteeeessss....
  651.  
  652.  
  653.  
  654.  
  655.  
  656.  
  657.                                                                        PPPPaaaaggggeeee 11110000
  658.  
  659.  
  660.  
  661.  
  662.  
  663.  
  664. DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))                                                        DDDDAAAATTTTFFFFRRRRAAAAMMMMEEEE((((4444))))
  665.  
  666.  
  667.  
  668.      The alphanumeric channel origin data consists of bytes 6 to 9 of the
  669.      channel status data of the IEC serial digital interface stored in bytes 0
  670.      to 3 of ddddaaaattttaaaa....ccccoooodddd....ccccoooodddd....
  671.  
  672.      The alphanumeric channel destination data consists of byte 22 of the
  673.      channel status data of the IEC serial digital interface stored in
  674.      ddddaaaattttaaaa....ccccdddddddd....ffffllllaaaaggggssss and bytes 10 to 13 of the channel status data stored in
  675.      bytes 0 to 4 of ddddaaaattttaaaa....ccccdddddddd....ccccdddddddd....
  676.  
  677.    PPPPaaaacccckkkk PPPPaaaarrrriiiittttyyyy
  678.      The last byte of a pack is a parity checksum which is computed as the
  679.      exclusive-OR of the first seven bytes.  During playback, the DAT drive
  680.      executes a parity check and only returns packs with correct parity.
  681.      During recording, the correct parity value must be computed and written
  682.      into the parity field before the pack is written to the tape.
  683.  
  684. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  685.      _T_h_e _D_i_g_i_t_a_l _A_u_d_i_o _T_a_p_e _R_e_c_o_r_d_e_r _S_y_s_t_e_m published by The DAT Conference.
  686.      c/o Electronic Industries Association of Japan, Engineering Department.
  687.      Tokyo Chamber of Commerce & Industry Building 2-2, 3-chome, Marunouchi,
  688.      Chiyoda-ku, Tokyo 100, Japan
  689.  
  690.      _D_A_T _f_o_r _P_r_o_f_e_s_s_i_o_n_a_l _U_s_e.  The DAT Conference. c/o Electronic Industries
  691.      Association of Japan, Engineering Department.  Tokyo Chamber of Commerce
  692.      & Industry Building 2-2, 3-chome, Marunouchi, Chiyoda-ku, Tokyo 100,
  693.      Japan
  694.  
  695. AAAAUUUUTTTTHHHHOOOORRRR
  696.      Mark Callow
  697.  
  698.  
  699.  
  700.  
  701.  
  702.  
  703.  
  704.  
  705.  
  706.  
  707.  
  708.  
  709.  
  710.  
  711.  
  712.  
  713.  
  714.  
  715.  
  716.  
  717.  
  718.  
  719.  
  720.  
  721.  
  722.  
  723.                                                                        PPPPaaaaggggeeee 11111111
  724.  
  725.  
  726.  
  727.